package com.aviation.sell_ticket.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.time.LocalTime;
import java.util.Date;
import java.util.Map;

//航班表
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Aviation_flight implements Cloneable{

    //航班id
    private String flight_id;

    //航班号
    private String flight_name;

    //起飞机场
    private Integer airport_setout;

    //到达机场
    private Integer airport_arrive;

    //出发时间
    private LocalTime departure_time;

    //到达时间
    private LocalTime arrival_time;

    //时间间隔
    private Integer time_difference;

    //航班初次启用时间
    private LocalDate initial_time;

    //间隔时间
    private Integer aviation_rotate;

    //航班是否停运
    private Integer outage;

    //停运截止时间
    private LocalDateTime outage_time;

    //航班型号
    private Integer model_id;

    //起飞机场信息
    private Aviation_airport setout_information;

    //目的地机场信息
    private Aviation_airport arrive_information;

    //出发地城市
    private Aviation_city departureCity;

    //目的地城市
    private Aviation_city destinationCity;

    //航班价格
    private Aviation_flight_price flightPrice;

    //机型信息
    private Aviation_model model;

    private Map<String,Integer> timeOfFlight;

    //出发时间
    private Map<String,String> departureTime;

    //地图航班出发时间
    private LocalDate departure;

    @Override
    public Aviation_flight clone() {
        try {
            Aviation_flight clone = (Aviation_flight) super.clone();
            // TODO: copy mutable state here, so the clone can't change the internals of the original
            return clone;
        } catch (CloneNotSupportedException e) {
            throw new AssertionError();
        }
    }
}
